<!DOCTYPE html>
<html>
<head>
    <title>移动web日期选择组件</title>
    <meta http-equiv="Content-Type" content="text/html" charset="utf-8">
    <meta content="name" charset="Rodey">
    <meta content="keyword" charset="反馈">
    <meta content="descriptions" charset="天下通意见反馈管理">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-status-bar-style" content="black-translucent">
    <meta name="viewport" content="width=640,target-densitydpi=320,user-scalable=no"/>
    <meta name="format-detection" content="telephone=no" />
    <link rel="stylesheet" href="css/app.css">
</head>
<body>
    <div id="app">

        <input type="text" id="date" readonly class="date-input">
        <button id="choiesDate" class="date-btn">选择日期</button>
        <!--日期选择组件模板-->
        <!--<div class="app-dateField-main">
            <div class="app-dateField-top">
                <span class="app-dateField-btnCancel">取消</span>
                <span class="app-dateField-btnOk">完成</span>
            </div>
            <div class="app-dateField-center">
                <ul class="app-dateField-year-con"></ul>
                <ul class="app-dateField-month-con"></ul>
                <ul class="app-dateField-date-con"></ul>
            </div>
            <div class="app-dateField-bottom"></div>
        </div>-->
    </div>

<!--载入js-->
<script src="js/jquery-1.9.1.min.js"></script>
<script src="js/jquery.touch.js"></script>
<script src="js/APPDateField.js"></script>

<script>

    $(document).ready(function(){


        var dateBtn = $('#date');
        var choiesDateBtn = $('#choiesDate');

        var appDateField;

        var choiesDate = function(evt){
            appDateField = new APPDateField('date', {
                isCN: true,
                commer: '/',
                showYear: true,
                showMonth: true,
                showDate: true,
                complate: function(date){
                    console.log(this);
                    console.log(this.getCurrentDate(0, 0, 0));
                    console.log(this.currDate);
                },
                cancel: function(){
                    console.log('[已取消]  Cancel----');
                }
            });
        };

        dateBtn.on('tap', choiesDate);
        choiesDateBtn.on('tap', choiesDate);

    });

</script>


</body>
</html>